<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml"
	xmlns:ui="http://java.sun.com/jsf/facelets"
	xmlns:h="http://java.sun.com/jsf/html"
	xmlns:f="http://java.sun.com/jsf/core"
	xmlns:p="http://primefaces.org/ui">

<ui:composition>
	<h:panelGrid columns="2">
		<h:panelGrid id="promotionInfoInputPanel" columns="2"
			rendered="#{promotionModel.current != null}" style="width:100%">
			<h:outputText value="id" />
			<h:outputText value="#{promotionModel.current.id}" />
			<h:outputText value="Number" />
			<h:inputText value="#{promotionModel.current.number}" />
			<h:outputText value="Title" style="width:200px"/>
			<h:panelGrid columns="5">
				<h:inputText value="#{promotionModel.current.title}" />			
				<h:outputText value="Chinese" />
				<h:inputText value="#{promotionModel.current.chineseTitle}" />				
				<h:outputText value="French" />
				<h:inputText value="#{promotionModel.current.frenchTitle}" />				
			</h:panelGrid>
			<h:outputText value="Start date" />
			<p:calendar  value="#{promotionModel.current.startDate}" />
			<h:outputText value="End date" />
			<p:calendar  value="#{promotionModel.current.endDate}" />
			<h:outputText value="Reward rate" />
			<p:spinner value="#{promotionModel.current.rewardRate}" min="0" max="30" stepFactor="1" suffix="%" />
			<h:outputText value="Minimun amount" />
			<p:spinner value="#{promotionModel.current.minAmount}" min="0" stepFactor="1" suffix="$"/>
			<h:outputText value="Marketing media" />
			<h:inputText value="#{promotionModel.current.marketingMedia}" />
			<h:outputText value="Promotion Code" />
			<h:inputText value="#{promotionModel.current.code}" />
			<h:outputText value="Comments" />
			<h:panelGrid columns="5">
				<h:inputTextarea value="#{promotionModel.current.comments}" />
				<h:outputText value="Chinese" />
				<h:inputTextarea value="#{promotionModel.current.chineseComments}" />
				<h:outputText value="French" />
				<h:inputTextarea value="#{promotionModel.current.frenchComments}" />
			</h:panelGrid>
		</h:panelGrid>

	</h:panelGrid>
</ui:composition>

</html>